Conventionally, the Depth from Defocus (DFD) method such as that described in Japanese Patent Application Publication No. H01-167610 has been proposed as a method of acquiring a depth of a captured scene from an image acquired by an image pickup apparatus. In the DFD method, a plurality of images having different amounts of blur are acquired by controlling the imaging parameters of an imaging optical system, and the respective magnitudes and correlation amounts of blur are calculated by using measurement object pixels and pixels peripheral to these in the plurality of acquired images.
Since the magnitude and correlative amount of the blur change in accordance with the depth to the object in the image, the depth is calculated by using the relationship therebetween. With depth measurement by the DFD method, it is possible to calculate the depth by one imaging system, and, therefore, such a method is advantageous in that it can be incorporated into a commercially available image pickup apparatus.
In a conventional DFD method, the fact that the magnitude of blur due to the imaging optical system changes in accordance with the depth from the object is used to estimate the depth information of the object on the basis of the magnitude of blur in a plurality of images. Since the depth can be calculated theoretically, provided that the imaging conditions of the respective images are known, then no particular mention of desirable imaging conditions is made in the '610 document or in Japanese Patent No. 4403477. As a result of ongoing research, however, the inventors discovered that the imaging conditions that are set for the plurality of images to be acquired have an effect on the depth estimate accuracy (measurement accuracy), and the measurable range, and also, that the desirable imaging conditions vary depending on the characteristics of the imaging optical system.